Declare Function OpenSound Lib "Sound" () As Integer
Declare Sub CloseSound Lib "Sound" ()
Declare Function SetVoiceQueueSize Lib "Sound" (ByVal nVoice As Integer, ByVal nBytes As Integer) As Integer
Declare Function SetVoiceNote Lib "Sound" (ByVal nVoice As Integer, ByVal nValue As Integer, ByVal nLength As Integer, ByVal nCdots As Integer) As Integer
Declare Function SetVoiceAccent Lib "Sound" (ByVal nVoice As Integer, ByVal nTempo As Integer, ByVal nVolume As Integer, ByVal nMode As Integer, ByVal nPitch As Integer) As Integer
Declare Function SetVoiceEnvelope Lib "Sound" (ByVal nVoice As Integer, ByVal nShape As Integer, ByVal nRepeat As Integer) As Integer
Declare Function SetSoundNoise Lib "Sound" (ByVal nSource As Integer, ByVal nDuration As Integer) As Integer
Declare Function SetVoiceSound Lib "Sound" (ByVal nVoice As Integer, ByVal lFrequency As Long, ByVal nDuration As Integer) As Integer
Declare Function StartSound Lib "Sound" () As Integer
Declare Function StopSound Lib "Sound" () As Integer
Declare Function WaitSoundState Lib "Sound" (ByVal nState As Integer) As Integer
Declare Function SyncAllVoices Lib "Sound" () As Integer
Declare Function CountVoiceNotes Lib "Sound" (ByVal nVoice As Integer) As Integer
Declare Function GetThresholdEvent Lib "Sound" () As Integer
Declare Function GetThresholdStatus Lib "Sound" () As Integer
Declare Function SetVoiceThreshold Lib "Sound" (ByVal nVoice As Integer, ByVal nNotes As Integer) As Integer
' WaitSoundState() Constants
Global Const S_QUEUEEMPTY = 0
Global Const S_THRESHOLD = 1
Global Const S_ALLTHRESHOLD = 2
' Accent Modes
Global Const S_NORMAL = 0
Global Const S_LEGATO = 1
Global Const S_STACCATO = 2
' SetSoundNoise() Sources
Global Const S_PERIOD512 = 0 ' Freq = N/512 high pitch, less coarse hiss
Global Const S_PERIOD1024 = 1 ' Freq = N/1024
Global Const S_PERIOD2048 = 2 ' Freq = N/2048 low pitch, more coarse hiss
Global Const S_PERIODVOICE = 3 ' Source is frequency from voice channel (3)
Global Const S_WHITE512 = 4 ' Freq = N/512 high pitch, less coarse hiss
Global Const S_WHITE1024 = 5 ' Freq = N/1024
Global Const S_WHITE2048 = 6 ' Freq = N/2048 low pitch, more coarse hiss
Global Const S_WHITEVOICE = 7 ' Source is frequency from voice channel (3)
Global Const S_SERDVNA = (-1) ' Device not available
Global Const S_SEROFM = (-2) ' Out of memory
Global Const S_SERMACT = (-3) ' Music active
Global Const S_SERQFUL = (-4) ' Queue full
Global Const S_SERBDNT = (-5) ' Invalid note
Global Const S_SERDLN = (-6) ' Invalid note length